{{! -------------------------------------------------------------------------- }}
{{! Copyright 2002-2016, OpenNebula Project, OpenNebula Systems                }}
{{!                                                                            }}
{{! Licensed under the Apache License, Version 2.0 (the "License"); you may    }}
{{! not use this file except in compliance with the License. You may obtain    }}
{{! a copy of the License at                                                   }}
{{!                                                                            }}
{{! http://www.apache.org/licenses/LICENSE-2.0                                 }}
{{!                                                                            }}
{{! Unless required by applicable law or agreed to in writing, software        }}
{{! distributed under the License is distributed on an "AS IS" BASIS,          }}
{{! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   }}
{{! See the License for the specific language governing permissions and        }}
{{! limitations under the License.                                             }}
{{! -------------------------------------------------------------------------- }}
<form data-abide novalidate id="{{formPanelId}}Wizard" class="custom creation">
  <div class="row">
    <div class="medium-6 columns">
      <label for="NAME">
        {{tr "Name"}}
      </label>
      <input id="NAME" type="text" wizard_field="NAME" required/>
    </div>
    <div class="medium-3 columns" hidden>
      <label for="TYPE">{{tr "Type"}}</label>
      <select id="TYPE" wizard_field="TYPE" required>
        <option value="image">{{tr "Image"}}</option>
      </select>
    </div>
  </div>
  <div class="row">
    <div class="medium-6 columns">
      <label for="DESCRIPTION">
        {{tr "Description"}}
      </label>
      <textarea id="DESCRIPTION" wizard_field="DESCRIPTION" rows="1"></textarea>
    </div>
    <div class="medium-3 columns">
      <label for="VERSION">
        {{tr "Version"}}
      </label>
      <input id="VERSION" type="text" wizard_field="VERSION"/>
    </div>
    <div class="medium-3 columns">
    </div>
  </div>
  <fieldset>
    <legend>{{tr "Select the Image to create the App"}}</legend>
    {{{imagesTableHTML}}}
  </fieldset>
  <fieldset>
    <legend>{{tr "Select the Marketplace where the App will be created"}}</legend>
    {{{marketPlacesTableHTML}}}
  </fieldset>
  <fieldset>
  <legend>{{tr "Templates for the App"}}</legend>
  <div class="row">
    <div class="medium-6 columns">
      <label for="VMTEMPLATE">
        {{tr "VM template"}}
        {{{tip (tr "VM Template to be created. A DISK element pointing to the App Image will be automatically added when the App is exported")}}}
      </label>
      <textarea class="monospace" id="VMTEMPLATE" rows="4" wizard_field="VMTEMPLATE64" wizard_field_64="true" placeholder='ATTRIBUTE = "VALUE"'></textarea>
    </div>
    <div class="medium-6 columns">
      <label for="APPTEMPLATE">
        {{tr "App template"}}
      </label>
      <textarea class="monospace" id="APPTEMPLATE" rows="4" wizard_field="APPTEMPLATE64" wizard_field_64="true" placeholder='ATTRIBUTE = "VALUE"'></textarea>
    </div>
  </div>
  </fieldset>
</form>